package com.gitee.freakchicken.dbapi.apiserver.conf;

import com.gitee.freakchicken.dbapi.basic.filter.C_bv967S5S;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.boot.web.servlet.FilterRegistrationBean;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

@Slf4j
@Configuration
public class C_6rx8oCt9 {

    @Value("${dbapi.api.context}")
    String gf_3FvjUXKn;

    @Autowired
    private C_bv967S5S gf_MjYEI5q3;

    @Bean
    public FilterRegistrationBean m_y9g8PzY7() {
        int lf_JCExRfy0 = 2;
        String lf_91CNIADf = String.format("/%s/*", gf_3FvjUXKn);
        FilterRegistrationBean lf_yc0teKol = new FilterRegistrationBean();
        lf_yc0teKol.setFilter(gf_MjYEI5q3);
        lf_yc0teKol.addUrlPatterns(lf_91CNIADf);
        lf_yc0teKol.setOrder(lf_JCExRfy0);
        lf_yc0teKol.setEnabled(true);
        log.info("regist authFilter for {} UrlPatterns, and order is {}", lf_91CNIADf, lf_JCExRfy0);
        return lf_yc0teKol;
    }
}
